//
//  packCollectionViewCell.m
//  Journey
//
//  Created by dllo on 16/5/20.
//  Copyright © 2016年 dllo. All rights reserved.
//

#import "packCollectionViewCell.h"
#import "UIImageView+WebCache.h"
@implementation packCollectionViewCell

-(instancetype)initWithFrame:(CGRect)frame{
    self = [super initWithFrame:frame];
    if (self) {
        [self createPack];
    }
    return self;
}

-(void)createPack
{
    self.photo = [[UIImageView alloc] init];
    [self.contentView addSubview:self.photo];
    self.photo.backgroundColor = [UIColor lightGrayColor];
}

-(void)layoutSubviews
{
    [super layoutSubviews];
    self.photo.frame = self.contentView.bounds;
}


-(void)setGuides:(guidesModel *)guides{
    _guides = guides;
    [self.photo sd_setImageWithURL:[NSURL URLWithString:[NSString stringWithFormat:@"%@/140_210.jpg?cover_updatetime=%@",guides.cover,guides.cover_updatetime]] placeholderImage:[UIImage imageNamed:@"image1"]];
}


@end
